using System;
using System.Collections.Generic;
using System.Text;
using eShop.Model;

namespace AutoGear.BLL
{
    public class ProductCategoryNameCompare : IComparer<Category>
    {
        #region IComparer<ProductBrand> Members

        public int Compare(Category x, Category y)
        {
            return x.CategoryName.CompareTo(y.CategoryName);
        }

        #endregion
    }

    public class ProductCategoryNameDescendingCompare : IComparer<Category>
    {
        #region IComparer<ProductBrand> Members

        public int Compare(Category x, Category y)
        {
            return y.CategoryName.CompareTo(x.CategoryName);
        }

        #endregion
    }

    public class ProductCategoryIdCompare : IComparer<Category>
    {

        #region IComparer<ProductBrand> Members

        public int Compare(Category x, Category y)
        {
            return x.CategoryId.CompareTo(y.CategoryId);
        }

        #endregion
    }
}
